<?php defined('SYSPATH') or die('No direct script access.'); ?>

<?php foreach($root_categories as $category) : ?>
<h2><?php echo $category->name; ?></h2>
<table>
		<?php foreach($category->subcategories->find_all() as $sub): ?>
		<tr>
		<td>
			<?php echo $sub->name; ?>
			<?php echo Html::anchor('admin/merchmanagement/inventory/edit/'.$sub->id, 'Manage Inventory')?>
		</td>
		</tr>
		<?php endforeach;?>
</table>
	<?php endforeach;?>